package router

import (
	"broker/interface/iserver"
	"broker/utils/logger"
)

type ErrorRouter struct {
	BaseRouter
}

func NewErrorRouter() *ErrorRouter {
	return &ErrorRouter{}
}

func (er *ErrorRouter) HandleByMessage(request iserver.IRequest, data []byte) {
	logger.Info.Println("[Router] Call Router Handle...")

	logger.Info.Println("Router] Recv from client :msgId = ", request.GetMsgID(), ",data = ", string(request.GetData()))

	//err := request.GetConnection().SendMsg(1, data)
	//if err != nil {
	//	fmt.Println(err)
	//}
}
